package com.ruoyi.swap.openapi.quotesTicker.service.impl;

import java.util.List;

import com.ruoyi.swap.openapi.orderbook.domain.VO.SwapOpenapiOrderbookVO;
import com.ruoyi.swap.openapi.quotesTicker.domain.VO.SwapOpenapiQuotesTickerVO;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.swap.openapi.quotesTicker.mapper.SwapOpenapiQuotesTickerMapper;
import com.ruoyi.swap.openapi.quotesTicker.domain.SwapOpenapiQuotesTicker;
import com.ruoyi.swap.openapi.quotesTicker.service.ISwapOpenapiQuotesTickerService;

/**
 * 行情tickerService业务层处理
 * 
 * @author saumell
 * @date 2024-08-19
 */
@Service
public class SwapOpenapiQuotesTickerServiceImpl implements ISwapOpenapiQuotesTickerService 
{
    @Autowired
    private SwapOpenapiQuotesTickerMapper swapOpenapiQuotesTickerMapper;

    /**
     * 查询行情ticker
     * 
     * @param id 行情ticker主键
     * @return 行情ticker
     */
    @Override
    public SwapOpenapiQuotesTickerVO selectSwapOpenapiQuotesTickerById(Integer id)
    {
        return swapOpenapiQuotesTickerMapper.selectSwapOpenapiQuotesTickerById(id);
    }

    /**
     * 查询行情ticker列表
     * 
     * @param swapOpenapiQuotesTicker 行情ticker
     * @return 行情ticker
     */
    @Override
    public List<SwapOpenapiQuotesTickerVO> selectSwapOpenapiQuotesTickerList(SwapOpenapiQuotesTickerVO swapOpenapiQuotesTicker)
    {
        return swapOpenapiQuotesTickerMapper.selectSwapOpenapiQuotesTickerList(swapOpenapiQuotesTicker);
    }

    @Override
    public List<SwapOpenapiQuotesTickerVO> selectSwapAllData() {
        return swapOpenapiQuotesTickerMapper.selectSwapAllData();
    }

    @Override
    public Integer queryCurryNumber(String currencyPair) {
        return swapOpenapiQuotesTickerMapper.queryCurryNumber(currencyPair);
    }

    /**
     * 新增行情ticker
     * 
     * @param swapOpenapiQuotesTicker 行情ticker
     * @return 结果
     */
    @Override
    public int insertSwapOpenapiQuotesTicker(SwapOpenapiQuotesTicker swapOpenapiQuotesTicker)
    {
        return swapOpenapiQuotesTickerMapper.insertSwapOpenapiQuotesTicker(swapOpenapiQuotesTicker);
    }

    /**
     * 修改行情ticker
     * 
     * @param swapOpenapiQuotesTicker 行情ticker
     * @return 结果
     */
    @Override
    public int updateSwapOpenapiQuotesTicker(SwapOpenapiQuotesTicker swapOpenapiQuotesTicker)
    {
        return swapOpenapiQuotesTickerMapper.updateSwapOpenapiQuotesTicker(swapOpenapiQuotesTicker);
    }

    /**
     * 批量删除行情ticker
     * 
     * @param ids 需要删除的行情ticker主键
     * @return 结果
     */
    @Override
    public int deleteSwapOpenapiQuotesTickerByIds(Integer[] ids)
    {
        return swapOpenapiQuotesTickerMapper.deleteSwapOpenapiQuotesTickerByIds(ids);
    }

    /**
     * 删除行情ticker信息
     * 
     * @param id 行情ticker主键
     * @return 结果
     */
    @Override
    public int deleteSwapOpenapiQuotesTickerById(Integer id)
    {
        return swapOpenapiQuotesTickerMapper.deleteSwapOpenapiQuotesTickerById(id);
    }
}
